package com.nmsl.medicine.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.nmsl.medicine.mapper.MedicineStorageOutRecordMapper;
import com.nmsl.medicine.domain.MedicineStorageOutRecord;
import com.nmsl.medicine.service.IMedicineStorageOutRecordService;

/**
 * 药品出库记录Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-02-20
 */
@Service
public class MedicineStorageOutRecordServiceImpl implements IMedicineStorageOutRecordService 
{
    @Autowired
    private MedicineStorageOutRecordMapper medicineStorageOutRecordMapper;

    /**
     * 查询药品出库记录
     * 
     * @param storageOutId 药品出库记录主键
     * @return 药品出库记录
     */
    @Override
    public MedicineStorageOutRecord selectMedicineStorageOutRecordByStorageOutId(Long storageOutId)
    {
        return medicineStorageOutRecordMapper.selectMedicineStorageOutRecordByStorageOutId(storageOutId);
    }

    /**
     * 查询药品出库记录列表
     * 
     * @param medicineStorageOutRecord 药品出库记录
     * @return 药品出库记录
     */
    @Override
    public List<MedicineStorageOutRecord> selectMedicineStorageOutRecordList(MedicineStorageOutRecord medicineStorageOutRecord)
    {
        return medicineStorageOutRecordMapper.selectMedicineStorageOutRecordList(medicineStorageOutRecord);
    }

    /**
     * 新增药品出库记录
     * 
     * @param medicineStorageOutRecord 药品出库记录
     * @return 结果
     */
    @Override
    public int insertMedicineStorageOutRecord(MedicineStorageOutRecord medicineStorageOutRecord)
    {
        return medicineStorageOutRecordMapper.insertMedicineStorageOutRecord(medicineStorageOutRecord);
    }

    /**
     * 修改药品出库记录
     * 
     * @param medicineStorageOutRecord 药品出库记录
     * @return 结果
     */
    @Override
    public int updateMedicineStorageOutRecord(MedicineStorageOutRecord medicineStorageOutRecord)
    {
        return medicineStorageOutRecordMapper.updateMedicineStorageOutRecord(medicineStorageOutRecord);
    }

    /**
     * 批量删除药品出库记录
     * 
     * @param storageOutIds 需要删除的药品出库记录主键
     * @return 结果
     */
    @Override
    public int deleteMedicineStorageOutRecordByStorageOutIds(Long[] storageOutIds)
    {
        return medicineStorageOutRecordMapper.deleteMedicineStorageOutRecordByStorageOutIds(storageOutIds);
    }

    /**
     * 删除药品出库记录信息
     * 
     * @param storageOutId 药品出库记录主键
     * @return 结果
     */
    @Override
    public int deleteMedicineStorageOutRecordByStorageOutId(Long storageOutId)
    {
        return medicineStorageOutRecordMapper.deleteMedicineStorageOutRecordByStorageOutId(storageOutId);
    }
}
